
import login from "./public/cook/port/login"
import registry from "./public/cook/port/registry"
import remove from "./public/cook/port/remove"
import amend from "./public/cook/port/amend"
import check from "./public/cook/port/check"
import sort from "./public/cook/port/sort"
import getstudent from "./public/paging/port/getstudent"


function httpEnd(req, res, ent) {
    let pathname = req.pathname
    const obj={
        //登录注册 以及菜品的增删改查接口
        "/login❤GET": login,// 登录
        "/registry❤POST": registry,//注册
        "/remove❤POST": remove,//删除
        "/amend❤POST": amend,//修改
        "/check❤POST": check,//查询
        "/sort❤POST": sort,//排序
        //学生管理页面分页接口
        "/getstudent❤GET":getstudent,
         
        

    }
    if(obj[`${pathname}❤${ent}`]){
        return obj[`${pathname}❤${ent}`](req,res)
    }
    return false
}


export default httpEnd